package org.ssm.demo.schedule;

/**
 * @Author: Junerain
 * @Description:
 * @Date:Created in 9:13 2018/4/25
 * @Modified By:
 */
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.springframework.scheduling.quartz.QuartzJobBean;
//import com.dennis.walking.api.service.OrderService;

import java.util.Date;

//@Component
public class printNameJob extends QuartzJobBean {

    private static int counter = 0;

    protected void executeInternal(JobExecutionContext context) throws JobExecutionException {
        try {
            long ms = System.currentTimeMillis();
            System.out.println("王宇"+ counter+++"-----------"+new Date(ms));
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}

